package com.tydic.system.service;


import com.tydic.system.domain.Account;
import com.tydic.system.domain.Company;
import com.tydic.system.domain.req.*;
import com.tydic.system.domain.resp.*;

public interface IFddService {

    /**
     * 获取tokn
     *
     * @return
     */
    String getToken();

    /**
     * 获取账号
     *
     * @param mobile
     * @return
     */
    Account getAccountByMobile(String mobile);

    /**
     * 获取账号
     *
     * @param accountId
     * @return
     */
    Account getAccountById(String accountId);

    /**
     * 创建账号
     *
     * @param account
     * @return
     */
    String createAccount(Account account);

    /**
     * 个人实名认证
     *
     * @param mobile
     * @param idCard
     * @param personalBankCard
     * @return
     */
    String verifyAccount(String name, String mobile, String idCard, String personalBankCard, String returnUrl);


    /**
     * 变更个人实名认证
     *
     * @param mobile
     * @param idCard
     * @param personalBankCard
     * @return
     */
    String verifyChangeAccount(String name, String mobile, String idCard, String personalBankCard, String returnUrl);


    /**
     * 获取企业
     *
     * @param companyName
     * @return
     */
    Company getCompanyByCompanyName(String companyName);

    /**
     * 获取企业
     *
     * @param companyId
     * @return
     */
    Company getCompanyByCompanyId(String companyId);

    /**
     * 创建企业
     *
     * @param company
     * @return
     */
    String createCompany(Company company);


    /**
     * 企业实名认证
     *
     * @param mobile
     * @param companyName
     * @param creditCode
     * @param bankName
     * @param bankNumber
     * @param branchName
     * @return
     */
    String verifyCompany(String mobile, String companyName, String creditCode, String bankName, String bankNumber, String branchName, String returnUrl);

    /**
     * 变更企业实名认证
     *
     * @param mobile
     * @param companyName
     * @param creditCode
     * @param bankName
     * @param bankNumber
     * @param branchName
     * @return
     */
    String verifyChangeCompany(String mobile, String companyName, String creditCode, String bankName, String bankNumber, String branchName, String returnUrl);

    /**
     * 合同相关文件上传
     *
     * @param request
     * @return
     */
    String upload(FileUploadRequest request);

    /**
     * 创建并推送签署
     *
     * @param request
     * @return
     */
    CreateAndPushResponse createAndPush(CreateAndPushRequest request, String name);

    /**
     * 获取文档签署链接
     *
     * @param request
     * @return
     */
    String sign(FileSignRequest request);

    /**
     * 关闭文件签署
     *
     * @param request
     */
    void shutSignTask(ShutSignTaskRequest request);

    /**
     * 获取文档查看链接
     *
     * @param request
     */
    String pageView(PageViewRequest request);


    String getSignUrl(FileGetSignRepeatRequest request);


    DocDownloadResponse download(DocDownloadRequest request);

    /**
     * 开通免验证签服务
     *
     * @param request
     * @return
     */
    UnwantedAuthSignResponse openUnwantedAuthSign(UnwantedAuthSignRequest request);

    //查询免验证签状态
    UnwantedAuthSignStatusResponse searchUnwantedAuthSignStatus(SeachUnwantedAuthSignRequest request);


    //完成手动免验证签签署
    FinishUnwantedAuthSignResponse finishUnwantedAuthSign(FinishUnwantedAuthSignRequest request);


    //撤销或关闭免验证签服务
    CloseUnwantedAuthSignResponse closeUnwantedAuthSign(CloseUnwantedAuthSignRequest request);


    String uploadPfd(String docId);

    String uploadImage(String docId);
}
